package com.flower.hooc.service;

import com.flower.hooc.bean.pojo.entity.Cart;
import org.springframework.stereotype.Service;

import java.math.BigDecimal;
import java.util.List;

@Service
public interface CartService {
    //根据用户ID查数据
    List<Cart> findCartByUserId(long userID);

    //根据用户Id删数据
    int deleteCartByUid(long userId);

    /**
     * 根据userId, courseId添加cart
     *
     * @param userId
     * @param courseId
     * @return
     */
    int addCart(long userId, long courseId, BigDecimal price);
}
